import {Component} from '@angular/core';
import {IonicPage} from 'ionic-angular';
import {StorageProvider} from "@providers/storage";

/**
 * Generated class for the ManagerTabsPage tabs.
 *
 * See https://ionicframework.com/docs/components/#navigation for more info on
 * Ionic pages and navigation.
 */

@IonicPage()
@Component({
  selector: 'page-manager-tabs',
  templateUrl: 'manager-tabs.html'
})
export class ManagerTabsPage {

  mdispatchRoot = 'ManagerOrderPage';
  mContactsRoot = 'ManagerContactsPage';
  mUserRoot = 'ManagerMyPage';
  messageHomePageRoot='MessageHomePage';

  constructor(private storageService: StorageProvider) {

  }

  ionViewWillEnter() {
    let userInfo:any=this.storageService.read('userInfo');
    userInfo.PCRM_CZY02= userInfo['RYXX01'];
    userInfo.PCRM_CZY03= userInfo['RYXX02'];
    userInfo.SessionID= userInfo['SessionID'];
    userInfo.PCRM_BM01= userInfo['PCRM_BM01'];
    userInfo.PCRM_GW01= -1;
    this.storageService.write('userInfo', userInfo);
  }
}
